// Fill out your copyright notice in the Description page of Project Settings.

#pragma once

#include "CoreMinimal.h"
#include "UObject/Interface.h"
#include "InputCoreTypes.h"
#include "CommenStruct.h"
#include "SaveInfoStruct.h"
#include "GameInstanceInterface.generated.h"


UINTERFACE(MinimalAPI)
class UGameInstanceInterface : public UInterface
{
	GENERATED_BODY()
};

class MISCELLANEOUSPROJECT_API IGameInstanceInterface
{
	GENERATED_BODY()

public:
	//=================Game===================
	virtual EGameState PassGameState() = 0;
	virtual bool UpdateGameState(const EGameState& DesiredGameState) = 0;
	virtual void GetGameWidgets(class UWidget*& OutBeginPlayWidget, class UWidget*& OutMainMenuWidget, class UWidget*& OutPauseMenuWidget,
		class UWidget*& OutLoadingScreenWidget,class UInGameWidget*& OutInGameWidget, class UInGameMenuWidget*& OutInGameMenuWidget) = 0;
	virtual void StartNewGame(const FSavedGameplayInfo& GameplayInfo,const FName& LevelName) = 0;
	virtual void OnAnyKey(FKey& AnyKey) = 0;
	//================Gameplay==============
	virtual void Request_Open_Level(const ELevelType& LevelType,const FName& LevelName,const FString& LoadedSlot) = 0;
	//================Save Game Library===========
	virtual FString GetDefaultSlotName() = 0;
	virtual bool SetCurrentSlot(const FString& CurrentSlot) = 0;
	virtual FString GetCurrentSlot() = 0;
	virtual bool UpdatePlayerSaveDataReference(const FSavedPlayerInfo& PlayerInfo) = 0;
	virtual FSavedPlayerInfo& GetPlayerSaveDataReference() = 0;
	virtual bool SetGameplaySaveDataReference(const FSavedGameplayInfo& GameplayInfo) = 0;
	virtual FSavedGameplayInfo& GetGameplaySaveDataReference() = 0;
	virtual bool UpdateMissionCSaveReference(FSavedMissionComponent& MissionComponent) = 0;
	virtual FSavedMissionComponent& GetMissionCSaveReference() = 0;
	virtual bool SaveCurrentProgress() = 0;
	virtual bool LoadSavedGame(const FString& FromSlot) = 0;
	//===============Widget Events======================
	virtual void DisplayGameWidget(const EGameState& GameState) = 0;
	virtual void HideLoadingScreen(const float& Delay) = 0;
	virtual void TogglePauseMenu() = 0;
	virtual void ToggleInGameMenu(const EInGameMenuType& MenuType) = 0;

};
